import java.util.*;

/**
 * @author gao
 * @date 2025/6/4 13:50
 */

public class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);

        while (scanner.hasNext()) {
            Customer customer1 = new Customer("小明",scanner.nextInt());
            Customer customer2 = new Customer("小军",scanner.nextInt());
            Customer customer3 = new Customer("小红",scanner.nextInt());

            List<Customer> customers = new ArrayList<>();
            customers.add(customer1);
            customers.add(customer2);
            customers.add(customer3);

            Collections.sort(customers);

            System.out.println(customers);
        }
    }
}

class Customer implements Comparable<Customer> {
    private String name;
    private int consumption;

    public Customer(String name, int consumption) {
        this.name = name;
        this.consumption = consumption;
    }

    @Override
    public String toString() {
        return "Customer{" +
                "name='" + name + '\'' +
                ", consumption=" + consumption +
                '}';
    }

    @Override
    public int compareTo(Customer o) {
        //根据消费来从大到小进行比较
        return o.consumption - this.consumption;
    }
}